{% extends "activities/activitiesbase.html" %}

{% comment %}
#    Copyright 2012 New Mexico EPSCoR
#
#    This file is part of Teacher's P.E.T.
#
#    Teacher's P.E.T. is free software: you can redistribute it and/or modify
#    it under the terms of the GNU General Public License as published by
#    the Free Software Foundation, either version 3 of the License, or
#    (at your option) any later version.
#
#    Teacher's P.E.T. is distributed in the hope that it will be useful,
#    but WITHOUT ANY WARRANTY; without even the implied warranty of
#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#    GNU General Public License for more details.
#
#    You should have received a copy of the GNU General Public License
#    along with Teacher's P.E.T..  If not, see <http://www.gnu.org/licenses/>.
{% endcomment %}

{% block subtitle %} - {{Activity.title}}{% endblock subtitle %}

{% block css %}
    {{block.super}}
    <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}css/activities.css" >
{% endblock css %}

{% block content %}
	{% load files %}
	{% get_file_list for Activity as Files %}
	
    <table class="activities">
		<tr>
			{% if ActivityCollection and ActivityCollection.show_collection_menu %}
				<td class="nowrap">
					{# Show TOC #}
					<div class="activities_menu {% if not Activity.content %}activities_menu_no_content{%endif%}">
						<ul>{{ActivityCollectionMenu|safe}}</ul>
					</div>
				 </td>
			{% endif %}
			<td>
				{% if Activity.content %}
					<form action="." method="post" enctype="multipart/form-data">{% csrf_token %}
						<div class="form_container activities_content {% if ActivityCollection and ActivityCollection.show_collection_menu %}activities_collection{%endif%}">
							{% render Activity.content %}
							{% if Questions.has_form %}
								<button type="submit" class="button SaveButton" name="Save" value="Save">Submit</button>
							{% endif %}
						</div>
					</form>
				{% endif %}
			</td>
		</tr>
    </table>
{% endblock content %}